home *** CD-ROM | disk | FTP | other *** search
/ The Games Machine 75 / XENIATGM75.iso / Shareware / X-Setup 5.0 / _SETUP.1 / XQ WinNT Old Startup.xpl < prev    next >
Text File  |  1999-07-07  |  2KB  |  66 lines

  1. "FILE"="Xteq Systems X-Setup Plugin 5.0"
  2. "TYPE"="1"
  3. "COUNT"="2"
  4. "UIPATH"="System\Startup\"
  5. "NAME"="Win16 startup commands"
  6. "VERSION"="1.31"
  7. "LANGUAGE"="VBScript"
  8. "TEXT 1"="LOAD command"
  9. "TEXT 2"="RUN command"
  10. "TEXT 3"="win.ini LOAD"
  11. "TEXT 4"="win.ini RUN"
  12. "DESCRIPTION 1"="In Windows 3.x (Win 16bit) the only way to start a program automatically when Windows loads were the commands "RUN" and "LOAD" in WIN.INI. "
  13. "DESCRIPTION 2"="Although Windows now supports many other options to do the same, RUN and LOAD are still supported and some programs keep on using it."
  14. "DESCRIPTION 3"="To make the confusion complete, Windows supports these commands in BOTH registry and win.ini."
  15. "DESCRIPTION 4"="Note #1: Use only short file names (8+3), no spaces!"
  16. "DESCRIPTION 5"="Note #2: To execute two or more commands, separate the commands using a single space."
  17. "AUTHOR"="Xteq Systems"
  18. "COPYRIGHT"="Copyright ⌐ Xteq Systems - All Rights Reserved"
  19. "COMMENT 1"="For more information, go to http://www.xteq.com or write to TeXHeX@xteq.com"
  20.  
  21.  
  22. sPath="HKCU\Software\Microsoft\Windows NT\CurrentVersion\Windows\"
  23. sV1="LOAD"
  24. sV2="RUN"
  25.  
  26. sFile="WIN.INI"
  27. sFileSec="WINDOWS"
  28.  
  29. Sub Plugin_Initialize 
  30.  s=RegReadValue(sPath&sV1)
  31.  if len(s)=0 then s=INIReadValue(sFile,sFileSec,sV1)
  32.  Call SetUIElement(1,s)
  33.  
  34.  s=RegReadValue(sPath&sV2)
  35.  if len(s)=0 then s=INIReadValue(sFile,sFileSec,sV2)
  36.  Call SetUIElement(2,s)
  37. End Sub
  38.  
  39. Sub Plugin_CheckData(ElementIndex)
  40. End Sub
  41.  
  42. Sub Plugin_Apply(ElementIndex,ElementSubIndex)
  43.  s=GetUIElement(1)
  44.  Call RegWriteValue(sPath&sV1,s,1)
  45.  
  46.  s=GetUIElement(2)
  47.  Call RegWriteValue(sPath&sV2,s,1)
  48.  
  49.  
  50.  'Seems like unnecessary, but these commands ensure that the registry- and
  51.  'INI commands match...
  52.  
  53.  s=GetUIElement(1)
  54.  Call INIWriteValue(sFile,sFileSec,sV1,s)
  55.  
  56.  s=GetUIElement(2)
  57.  Call INIWriteValue(sFile,sFileSec,sV2,s)
  58.  
  59.  
  60.  
  61.  Call Restart
  62. End Sub
  63.  
  64. Sub Plugin_Terminate 
  65. End Sub
  66.